CommandPaste Class Reference

#include <CommandPaste.h>

Inheritance diagram for CommandPaste:

Command List of all members.

Public Member Functions

 CommandPaste (osg::Vec3 pos, OSGWindows *osgwind)
bool execute ()
bool unexecute ()

Private Attributes

OSGWindows * osgwind_
TrafficSign * sign
TrafficLight * light
Vehicle * vehicle
EnvironmentObject * envObj
vector< TraffEduObject * > pastedObjs_
vector< TraffEduObject * > tmpObjs_
char whichVector

Constructor & Destructor Documentation

CommandPaste::CommandPaste (  osg::Vec3  pos,
OSGWindows *  osgwind
) 
 

A constructor. Initializes osgwind_ and creates the pasted objects.

Parameters:
pos a osg::Vec3 argument.
osgwind an OSGWindows pointer.


Member Function Documentation

bool CommandPaste::execute (   )  [virtual]
 

do the paste operation.

Returns:
Operation success

Implements Command.

bool CommandPaste::unexecute (   )  [virtual]
 

undo the paste operation.

Returns:
Operation success

Implements Command.


Member Data Documentation

EnvironmentObject* CommandPaste::envObj [private]
 

a private variable. It is used to hold the created environmental object by using the pasted object information.

TrafficLight* CommandPaste::light [private]
 

a private variable. It is used to hold the created traffic light object by using the pasted object information.

OSGWindows* CommandPaste::osgwind_ [private]
 

a private variable. It is initialized with the unique OSGWindows instance.

vector<TraffEduObject*> CommandPaste::pastedObjs_ [private]
 

a private vector of TraffEduObjects. It holds the pasted objects.

TrafficSign* CommandPaste::sign [private]
 

a private variable. It is used to hold the created traffic sign object by using the pasted object information.

vector<TraffEduObject*> CommandPaste::tmpObjs_ [private]
 

a private vector of TraffEduObjects. It holds the copied or cut objects beforehand.

Vehicle* CommandPaste::vehicle [private]
 

a private variable. It is used to hold the created vehicle object by using the pasted object information.

char CommandPaste::whichVector [private]
 

a private variable. It is used to show from which vector the pasted objects are coming(copied or cut).


The documentation for this class was generated from the following file:
Generated on Sun May 28 18:44:00 2006 by  doxygen 1.4.6-NO